﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;

namespace TeamBuy.AccessWebUI
{
    public partial class Reged : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Request.QueryString["RegedUserID"] == "" || Request.QueryString["RegedUserID"] == null)
            {
                Response.Redirect("~/Reg.aspx");
            }
            else
            {
                TeamBuy.AccessService.TeamBuyUserService getUser = new AccessService.TeamBuyUserService();
                DataTable dtRegUser = getUser.GetUser(Convert.ToInt32(Common.PublicFunction.DESDecrypt(Request.QueryString["RegedUserID"].ToString())));
                ltlUserEmail.Text = dtRegUser.Rows[0]["UserEmail"].ToString();
                //ltlBottomUserEmail.Text = dtRegUser.Rows[0]["UserEmail"].ToString();
                //string activeLink = "ID=" + Common.PublicFunction.DESEncrypt(dtRegUser.Rows[0]["UserID"].ToString()) + "&Date=" + Common.PublicFunction.DESEncrypt(dtRegUser.Rows[0]["DateCreated"].ToString()) + "&Mail=" + Common.PublicFunction.DESEncrypt(dtRegUser.Rows[0]["UserEmail"].ToString());
                //Common.PublicFunction.SendMailToUser("", dtRegUser.Rows[0]["UserEmail"].ToString(), "test", activeLink, "", 0, "");
            }
            //hlkMailLink.NavigateUrl = "http://mail.163.com";
            //ShowMailLink.Visible = true;
        }
    }
}